<template>
<view class="t-weight">
    <view class="weight_box">{{weightNum}}</view>
    <view class="info_box">
      <view>地磅编号：HNHX-CL-01</view>
      <view>单位：KG</view>
    </view>
    <button class="mini-btn" type="primary" size="mini">按钮</button>
    <van-field class="van-input" v-model="mobile" type="tel" placeholder="请输入手机号" clearable maxlength="11" />
    <!-- <uni-card title="基础卡片" extra="额外信息">
				<text class="uni-body">这是一个基础卡片示例，此示例展示了一个标题加标题额外信息的标准卡片。</text>
    </uni-card> -->
</view>
</template>

<script setup>
import {
    useOutsideCountStore
} from '../../store/count'
const useCountStore = useOutsideCountStore()
const weightNum = ref(0)
const count = computed(() => useCountStore.count)

const {
    listDecompose
} = useRequest()
const url = ref('https://ext.dcloud.net.cn/plugin?id=1931')
const cur = ref('0')
const value = ref('123456')
const list = ref([])
const getList = () => {
    uni.showLoading({
        title: '加载中...'
    })
    listDecompose()
        .then((res) => {
            console.log(res)
            list.value = res.rows
            uni.hideLoading()
        })
        .catch(() => {
            uni.hideLoading()
        })
}
const toLogin = () => {
  uni.navigateTo({
    url:'/pages/login/index'
  })
}
onMounted(() => {
    getList()
})
</script>

<style lang="scss" scoped>
.t-weight{
  .weight_box{
    width: 100%;
    height: 300rpx;
    background-color: #2a82e4;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 180rpx;
  }
  .info_box{
    display: flex;
    height: 80rpx;
    box-sizing: border-box;
    justify-content: space-between;
    align-items: center;
    padding: 0 10rpx;
    border-bottom: 1px solid #999;
    view{
      color: #666;
    }
  }
}
</style>
